import CommonApi from './common'
// 首页统计概览
class OverviewApi extends CommonApi {
    constructor() {
        const scope = '/roadEvaluateBase'
        super(scope)
    }

    // 获取当前有权限的公路列表和坐标点集合
    getRoadList(data) {
        const path = '/coordinate/list'
        return this.post(path, data)
    }

    // 获取以公路和设施划分的缺陷病害树结构
    getFlawDiseaseTree(data) {
        const path = '/inspectionDefectRecord/getTreeList'
        return this.post(path, data)
    }

    // 获取以公路和设施划分的养护工程树结构
    getProjectTree(data) {
        const path = '/maintProject/getHomeTreeList'
        return this.post(path, data)
    }

    // 获取渲染缺陷病害的饼状图数据
    getFlawChart(data) {
        const path = '/inspectionDefectRecord/countStatus'
        return this.post(path, data)
    }

    // 获取渲染养护工程的饼状图数据
    getProjectChart(data) {
        const path = '/maintProject/countByStatusAndProjectId'
        return this.post(path, data)
    }

    // 获取巡查记录列表
    getPatrolRecord(data) {
        const path = '/ins/record/selectInspectionRecordOverviewList'
        return this.post(path, data)
    }

    // 获取巡查记录列表
    getPatrolDetail(data) {
        const path = '/inspectionTask/selectTaskOperateContactDetail'
        return this.post(path, data)
    }

    // 查询高速路段下的相关设施
    getFacilityByRoad(data) {
        const path = '/locationPoint/list'
        return this.post(path, data)
    }

    // 查询高速公路树形结构
    getRoadTree(data) {
        const path = '/property/common/road/treeList'
        return this.post(path, data)
    }
}

export default OverviewApi
